package com.brand.data.service.yqdz;

import java.util.HashMap;

/**
 * @author scl.BlueOcean
 * @version 1.0
 * @date 2018年08月17 14:03
 * @description
 */
public class RequestHeader extends HashMap<String,String> {
    /**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private static RequestHeader initHeader = new RequestHeader();
    static {
        init(initHeader);
    }

    private static void init(RequestHeader initHeader) {
	    initHeader.put("Accept", "text/html, application/xhtml+xml, image/jxr, */*");
	    initHeader.put("Accept-Encoding", "gzip, deflate");
	    initHeader.put("Accept-Language", "zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3");
	    initHeader.put("Connection", "keep-alive");
	    initHeader.put("Host", "portal.faw-vw.com");
	    initHeader.put("User-Agent", "Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko");
    }

    public static RequestHeader initHeader(){
        return initHeader;
    }

    public static RequestHeader newAndInitHeader(){
        RequestHeader header = newHeader();
        init(header);
        return header;
    }
    public static RequestHeader newHeader(){
        return new RequestHeader();
    }
    
    public  RequestHeader addHead(String name,String value){
    	this.put(name, value);
    	return this;
    }
}
